package com.test.demo.dao.entity;

import java.io.Serializable;

public class TransferRecord implements Serializable {
    /**
     * 
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private Long id;

    /**
     * 转账人id
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private Long fromUserId;

    /**
     * 转账金额
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private Long changeMoney;

    /**
     * 消息事务id
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private String transactionId;

    /**
     * 被转账人id
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private Long toUserId;

    /**
     * 转账流水编号
     *
     * @mbg.generated 2020-10-28 15:48:15
     */
    private String recordNo;

    /**
     * transfer_record
     */
    private static final long serialVersionUID = 1L;

    /**
     * 
     * @return id 
     */
    public Long getId() {
        return id;
    }

    /**
     * 
     * @param id 
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * 转账人id
     * @return from_user_id 转账人id
     */
    public Long getFromUserId() {
        return fromUserId;
    }

    /**
     * 转账人id
     * @param fromUserId 转账人id
     */
    public void setFromUserId(Long fromUserId) {
        this.fromUserId = fromUserId;
    }

    /**
     * 转账金额
     * @return change_money 转账金额
     */
    public Long getChangeMoney() {
        return changeMoney;
    }

    /**
     * 转账金额
     * @param changeMoney 转账金额
     */
    public void setChangeMoney(Long changeMoney) {
        this.changeMoney = changeMoney;
    }

    /**
     * 消息事务id
     * @return transaction_id 消息事务id
     */
    public String getTransactionId() {
        return transactionId;
    }

    /**
     * 消息事务id
     * @param transactionId 消息事务id
     */
    public void setTransactionId(String transactionId) {
        this.transactionId = transactionId == null ? null : transactionId.trim();
    }

    /**
     * 被转账人id
     * @return to_user_id 被转账人id
     */
    public Long getToUserId() {
        return toUserId;
    }

    /**
     * 被转账人id
     * @param toUserId 被转账人id
     */
    public void setToUserId(Long toUserId) {
        this.toUserId = toUserId;
    }

    /**
     * 转账流水编号
     * @return record_no 转账流水编号
     */
    public String getRecordNo() {
        return recordNo;
    }

    /**
     * 转账流水编号
     * @param recordNo 转账流水编号
     */
    public void setRecordNo(String recordNo) {
        this.recordNo = recordNo == null ? null : recordNo.trim();
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", fromUserId=").append(fromUserId);
        sb.append(", changeMoney=").append(changeMoney);
        sb.append(", transactionId=").append(transactionId);
        sb.append(", toUserId=").append(toUserId);
        sb.append(", recordNo=").append(recordNo);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        TransferRecord other = (TransferRecord) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getFromUserId() == null ? other.getFromUserId() == null : this.getFromUserId().equals(other.getFromUserId()))
            && (this.getChangeMoney() == null ? other.getChangeMoney() == null : this.getChangeMoney().equals(other.getChangeMoney()))
            && (this.getTransactionId() == null ? other.getTransactionId() == null : this.getTransactionId().equals(other.getTransactionId()))
            && (this.getToUserId() == null ? other.getToUserId() == null : this.getToUserId().equals(other.getToUserId()))
            && (this.getRecordNo() == null ? other.getRecordNo() == null : this.getRecordNo().equals(other.getRecordNo()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getFromUserId() == null) ? 0 : getFromUserId().hashCode());
        result = prime * result + ((getChangeMoney() == null) ? 0 : getChangeMoney().hashCode());
        result = prime * result + ((getTransactionId() == null) ? 0 : getTransactionId().hashCode());
        result = prime * result + ((getToUserId() == null) ? 0 : getToUserId().hashCode());
        result = prime * result + ((getRecordNo() == null) ? 0 : getRecordNo().hashCode());
        return result;
    }
}